#include "ThreadPool.h"
int pwd(char* working_dir, int curr_folder, MYSQL* mysql)
{
    char sql[4096];
    sprintf(sql, "select path from virtual_file where id = %d", curr_folder);
    int ret = mysql_query(mysql, sql);
    MYSQL_QUERY_CHECK(ret, mysql);

    MYSQL_RES* result = mysql_store_result(mysql);
    MYSQL_ROW row = mysql_fetch_row(result);

    memcpy(working_dir, row[0], strlen(row[0]));
    mysql_free_result(result);
    return 0;
}
